﻿using ESP.Test.Entities;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Web;
using System.Web.Mvc;

namespace TestWeb.Controllers
{
    public class HomeController : Controller
    {
        //
        // GET: /Home/

        public ActionResult Index()
        {
            //where
            var predicate = new Expression<Func<UserInfo, bool>>[] { x => x.UserId == "1" };
            //orderby
            var orderby = new Expression<Func<UserInfo, Orderby>>[] { x => x.UserId.Ascending() };
            //update
            var update = new Expression<Func<UserInfo, Update>>[] { x => x.UserName.Update("test") };
            return View();
        }

    }
}
